<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<title>工作管理系统</title>

<link href="/static/themes/default/style.css" rel="stylesheet" type="text/css" media="screen"/>
<link href="/static/themes/css/core.css" rel="stylesheet" type="text/css" media="screen"/>
<link href="/static/themes/css/print.css" rel="stylesheet" type="text/css" media="print"/>
<link href="/static/uploadify/css/uploadify.css" rel="stylesheet" type="text/css" media="screen"/>
<!--[if IE]>
<link href="/static/themes/css/ieHack.css" rel="stylesheet" type="text/css" media="screen"/>
<![endif]-->

<script src="/static/js/speedup.js" type="text/javascript"></script>
<script src="/static/js/jquery-1.7.1.js" type="text/javascript"></script>
<script src="/static/js/jquery.cookie.js" type="text/javascript"></script>
<script src="/static/js/jquery.validate.js" type="text/javascript"></script>
<script src="/static/js/jquery.bgiframe.js" type="text/javascript"></script>
<script src="/static/xheditor/xheditor-1.1.12-zh-cn.min.js" type="text/javascript"></script>
<script src="/static/uploadify/scripts/swfobject.js" type="text/javascript"></script>
<script src="/static/uploadify/scripts/jquery.uploadify.v2.1.0.js" type="text/javascript"></script>

<script src="/static/js/dwz.core.js" type="text/javascript"></script>
<script src="/static/js/dwz.util.date.js" type="text/javascript"></script>
<script src="/static/js/dwz.validate.method.js" type="text/javascript"></script>
<script src="/static/js/dwz.regional.zh.js" type="text/javascript"></script>
<script src="/static/js/dwz.barDrag.js" type="text/javascript"></script>
<script src="/static/js/dwz.drag.js" type="text/javascript"></script>
<script src="/static/js/dwz.tree.js" type="text/javascript"></script>
<script src="/static/js/dwz.accordion.js" type="text/javascript"></script>
<script src="/static/js/dwz.ui.js" type="text/javascript"></script>
<script src="/static/js/dwz.theme.js" type="text/javascript"></script>
<script src="/static/js/dwz.switchEnv.js" type="text/javascript"></script>
<script src="/static/js/dwz.alertMsg.js" type="text/javascript"></script>
<script src="/static/js/dwz.contextmenu.js" type="text/javascript"></script>
<script src="/static/js/dwz.navTab.js" type="text/javascript"></script>
<script src="/static/js/dwz.tab.js" type="text/javascript"></script>
<script src="/static/js/dwz.resize.js" type="text/javascript"></script>
<script src="/static/js/dwz.dialog.js" type="text/javascript"></script>
<script src="/static/js/dwz.dialogDrag.js" type="text/javascript"></script>
<script src="/static/js/dwz.sortDrag.js" type="text/javascript"></script>
<script src="/static/js/dwz.cssTable.js" type="text/javascript"></script>
<script src="/static/js/dwz.stable.js" type="text/javascript"></script>
<script src="/static/js/dwz.taskBar.js" type="text/javascript"></script>
<script src="/static/js/dwz.ajax.js" type="text/javascript"></script>
<script src="/static/js/dwz.pagination.js" type="text/javascript"></script>
<script src="/static/js/dwz.database.js" type="text/javascript"></script>
<script src="/static/js/dwz.datepicker.js" type="text/javascript"></script>
<script src="/static/js/dwz.effects.js" type="text/javascript"></script>
<script src="/static/js/dwz.panel.js" type="text/javascript"></script>
<script src="/static/js/dwz.checkbox.js" type="text/javascript"></script>
<script src="/static/js/dwz.history.js" type="text/javascript"></script>
<script src="/static/js/dwz.combox.js" type="text/javascript"></script>
<script src="/static/js/dwz.print.js" type="text/javascript"></script>
<!--
<script src="/static/bin/dwz.min.js" type="text/javascript"></script>
-->
<script src="/static/js/dwz.regional.zh.js" type="text/javascript"></script>

<script type="text/javascript">
$(function(){
 DWZ.init("/static/dwz.frag.xml", {
    loginUrl:"login_dialog.html", loginTitle:"登录",  // 弹出登录对话框
//    loginUrl:"login.html",  // 跳到登录页面
    statusCode:{ok:200, error:300, timeout:301}, //【可选】
    pageInfo:{pageNum:"pageNum", numPerPage:"numPerPage", orderField:"orderField", orderDirection:"orderDirection"}, //【可选】
    debug:false,  // 调试模式 【true|false】
    callback:function(){
      initEnv();
      $("#themeList").theme({themeBase:"/static/themes"}); // themeBase 相对于index页面的主题base路径
    }
  });
});

//清理浏览器内存,只对IE起效，FF不需要
if ($.browser.msie) {
  window.setInterval("CollectGarbage();", 10000);
}
$('html').ajaxSend(function(event, xhr, settings) {
    function getCookie(name) {
        var cookieValue = null;
        if (document.cookie && document.cookie != '') {
            var cookies = document.cookie.split(';');
            for (var i = 0; i < cookies.length; i++) {
                var cookie = jQuery.trim(cookies[i]);
                // Does this cookie string begin with the name we want?
                if (cookie.substring(0, name.length + 1) == (name + '=')) {
                    cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
                    break;
                }
            }
        }
        return cookieValue;
    }
    if (!(/^http:.*/.test(settings.url) || /^https:.*/.test(settings.url))) {
        // Only send the token to relative URLs i.e. locally.
        xhr.setRequestHeader("X-CSRFToken", getCookie('csrftoken'));
    }
});
</script>
</head>
<body scroll="no">
  <div id="layout">
    <div id="header">
      <div class="headerNav">
        <a class="logo" href="">Logo</a>
        <ul class="nav">
            <li style="color: #ffc0cb;"> 工作管理系统 -- 演示版</li>
            <li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li>
            <li ><a href="/my/overview"  style="color: yellow;">welcome, {{user.username}}</a></li>
            <li style="color: yellow;"> {{ user_detail.dept.name }}</li>
            <li style="color: yellow;"> 直接主管:{{user_detail.superior_auth_user.last_name}}</li>
            <!-- <li><a href="/my/account" target="dialog" mask="true">修改资料</a></li> -->

            {%if user.is_authenticated %}
            <li><a href="/my/logout">退出</a></li>
            {% else %}
            <li><a href="/my/login">登录</a></li>
            {% endif %}
        </ul>
          <ul class="themeList" id="themeList">
          <li theme="default"><div class="selected">蓝色</div></li>
          <li theme="green"><div>绿色</div></li>
          <li theme="purple"><div>紫色</div></li>
          <li theme="silver"><div>银色</div></li>
        </ul>
      </div>
    </div>
    
    <div id="leftside">
      <div id="sidebar_s">
        <div class="collapse">
          <div class="toggleCollapse"><div></div></div>
        </div>
      </div>
      
<div id="sidebar">
        <div class="toggleCollapse"><h2>主菜单</h2><div>收缩</div></div>

        <div class="accordion" fillSpace="sidebar">


              <div class="accordionHeader">
                <h2><span>Folder</span>考勤管理</h2>
              </div>
              <div class="accordionContent">
                <ul class="tree treeFolder ">
                  <li><a href="/checkin/my" target="navTab"    rel="checkin_log_page">我的考勤</a></li>
                  <li><a href="/checkin/absence" target="navTab" rel="checkin_log_page">当月缺勤</a></li>
                  {% if checkin_tree %}
                  {%autoescape off%}
                  {{checkin_tree}}
                  {%endautoescape%}
                  {%endif%}
                </ul>
              </div>


              <div class="accordionHeader">
                <h2><span>Folder</span>工作计划</h2>
              </div>
              <div class="accordionContent">
                <ul class="tree treeFolder">
                  <li><a href="/schedule/" target="navTab" rel="schedule_list_page">我的计划</a></li>
                  <li><a href="/schedule/todo" target="navTab" rel="schedule_list_page">未填写计划</a></li>
                  <li><a href="/schedule/compose" target="navTab" rel="compose_shedule">撰写计划</a></li>
                  {%autoescape off%}
                  {{schedule_tree}}
                  {%endautoescape%}
                </ul>
              </div>


              <div class="accordionHeader">
                <h2><span>Folder</span>工作回顾</h2>
              </div>
              <div class="accordionContent">
                <ul class="tree treeFolder">
                  <li><a href="/review/" target="navTab" rel="review_list_page">我的回顾</a></li>
                  <li><a href="/review/unfinished" target="navTab" rel="review_list_page">未填写回顾</a></li>
                  {%if review_tree %}
                  {%autoescape off%}
                  {{review_tree}}
                  {%endautoescape%}
                  {%endif%}
                </ul>
               </div>


               <div class="accordionHeader">
                 <h2><span>Folder</span>工作审批</h2>
               </div>
               <div class="accordionContent">
                 <ul class="tree treeFolder">
                   <li><a href="/approved/list" target="navTab" rel="approve_list_page">上级批复</a></li>
                   {% if management_role %}
                   <li><a href="/approved/unapprove" target="navTab" rel="unapprove_list">待批复</a></li>
                   {% endif %}
                   {% if approve_tree %}
                   {%autoescape off%}
                  {{approve_tree}}
                  {%endautoescape%}
                  {%endif%}
                 </ul>
                </div>

            {%if user.is_superuser%}
                <div class="accordionHeader">
                  <h2><span>Folder</span>后台管理</h2>
                </div>
                <div class="accordionContent">
                   <ul class="tree treeFolder">
	                    <li><a href="/admin/holiday/list" target="navTab" rel="list_holiday_page">节假日</a></li>
	                    <li><a href="/admin/workday/list" target="navTab" rel="list_workday_page">工作日</a></li>
	                    <li><a href="/admin/workday/list" target="navTab" rel="list_workday_page">部门管理</a>
	                    <ul>
	                      <li><a href="/admin/user/create" target="navTab" rel="create_user_page">添加职员</a></li>
	                      <li><a href="/admin/dept/create" target="navTab" rel="create_dept_page">添加部门</a></li>
	                      {% if admin_tree %}
	                      {%autoescape off%}
	                      {{admin_tree}}
	                      {%endautoescape%}
	                      {% endif%}
	                    </ul>
	                    </li>
                    </ul>
                </div>
            {%endif%}
        </div>
      </div>
    </div>

    <div id="container">
      <div id="navTab" class="tabsPage">
        <div class="tabsPageHeader">
          <div class="tabsPageHeaderContent"><!-- 显示左右控制时添加 class="tabsPageHeaderMargin" -->
            <ul class="navTab-tab">
              <li tabid="main" class="main"><a href="javascript:void(0)"><span><span class="home_icon">我的主页</span></span></a></li>
            </ul>
          </div>
          <div class="tabsLeft">left</div><!-- 禁用只需要添加一个样式 class="tabsLeft tabsLeftDisabled" -->
          <div class="tabsRight">right</div><!-- 禁用只需要添加一个样式 class="tabsRight tabsRightDisabled" -->
          <div class="tabsMore">more</div>
        </div>
        <ul class="tabsMoreList">
          <li><a href="javascript:void(0)">我的主页</a></li>
        </ul>
        <div class="navTab-panel tabsPageContent">
          <div class="tabsContent">
              <!-- 我的主页里面的内容######################################### -->
              <div  class ="panel collapse"   minH='200'>
                  <h1>待办事务:  &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp; {{today|date:"Y-m-d"}} &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp; {{ day_of_week }}&nbsp;&nbsp;&nbsp;&nbsp;| &nbsp;&nbsp;&nbsp;&nbsp;  全年的第:{{ week_of_year }} 周.</h1>
                  <div >
                      <div align="left" style="margin:30px 36px 37px 38px;">


                              1,考勤:
                              {%  if first_login_time %}签到：{{first_login_time.hour}}:{{first_login_time.minute}}{%else%}<form name="login" action="/checkin/?navTabId=oviewview" method="post" style="color: red;" onsubmit="return validateCallback(this,navTabAjaxDone);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button type="submit" style="color:red;">1.签到</button></form>{%endif%}
                          &nbsp;&nbsp;&nbsp;&nbsp; /&nbsp;&nbsp;&nbsp;&nbsp;
                              {% if last_logout_time %}签退：{{last_logout_time}}{%else%}<form name="checkout" action="/checkin/out" onsubmit="return validateCallback(this,navTabAjaxDone);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button type="submit">2.签退</button></form>{%endif%}<br/><br/>
                          2,待填写工作报告。(<a href="/schedule/todo" target="navTab" rel="schedule_list_page" title="待填写工作计划" style="color: red;">___{{lack_schedule_cnt}}条___</a>)<br/><br/>
                          3,待填写工作回顾。(<a href="/review/unfinished" target="navTab" rel="schedule_list_page" title="待填写回顾" style="color: red;">___{{lack_review_cnt}}条___</a>)<br/><br/>
                          {% if management_role %} <br/><br/>
                          4,检查部门考勤情况。{%if dept_absence_cnt %}(<a href="/checkin/absence/dept" target="navTab" rel="checkin_log_page" title="待填写回顾" style="color: red;">___{{dept_absence_cnt}}个异常考勤___</a>)<br/><br/>{%endif%}
                          5,待审批工作报告。{%if dept_unapprove_cnt %}(<a href="/approved/unapprove" target="navTab" rel="unapprove_list" title="待批复" style="color: red;">___{{dept_unapprove_cnt}}个待批复___</a>)<br/><br/>{%endif%}
                          <!-- 6,待审阅工作回顾。  <br/><br/> -->
                          {% endif %}
                      </div>
                  </div >
              </div >
              <div  class ="panel collapse"   minH='222'>
                  <h1>我的信息</h1>
                  <div class="pageContent">
                      <form id="pagerForm" action="xxx"  method="post">
                          <div class="pageFormContent" >
                              <p>

                                  <label>用户名：</label>
                                  <input type="text" name="username" size="30" maxlength="30" class="textInput" readonly="true" value="{{user.last_name}}"/>
                              </p>
                              <p>
                                  <label>所属部门:</label><input type="text" name="username" size="30" maxlength="30" class="textInput" readonly="true" value="{{user_detail.dept.name}}"/>
                              </p>
                              <p>
                                  <label>职&nbsp;&nbsp;务:</label><input type="text" name="username" size="30" maxlength="30" class="textInput" readonly="true" value="{{user_detail.title}}"/>
                              </p>
                              <p>
                                  <label>上级主管:</label><input type="text" name="username" size="30" maxlength="30" class="textInput" readonly="true" value="{{user_detail.superior_auth_user.last_name}}"/>
                              </p>
                              <!--【可选】其它查询条件，业务有关，有什么查询条件就加什么参数-->
                              <p>
                                  <label>日常任务:</label><input type="text" name="username" size="30" maxlength="30" class="textInput" readonly="true" value="{{user_detail.schedule_list}}"/>
                              </p>

                          </div>
                      </form>
                  </div>
              </div >
              <!-- 我的主页里面的内容######################################### -->

          </div>
        </div>
      </div>
    </div>

    <div id="taskbar" style="left:0px; display:none;">
      <div class="taskbarContent">
        <ul></ul>
      </div>
      <div class="taskbarLeft taskbarLeftDisabled" style="display:none;">taskbarLeft</div>
      <div class="taskbarRight" style="display:none;">taskbarRight</div>
    </div>
    <div id="splitBar"></div>
    <div id="splitBarProxy"></div>
  </div>
  
  <div id="footer">Powered by <a href="http://www.djangoproject.com">Django</a> &copy; 2012</div>

<!--拖动效果-->
  <div class="resizable"></div>
<!--阴影-->
  <div class="shadow" style="width:508px; top:148px; left:296px;">
    <div class="shadow_h">
      <div class="shadow_h_l"></div>
      <div class="shadow_h_r"></div>
      <div class="shadow_h_c"></div>
    </div>
    <div class="shadow_c">
      <div class="shadow_c_l" style="height:296px;"></div>
      <div class="shadow_c_r" style="height:296px;"></div>
      <div class="shadow_c_c" style="height:296px;"></div>
    </div>
    <div class="shadow_f">
      <div class="shadow_f_l"></div>
      <div class="shadow_f_r"></div>
      <div class="shadow_f_c"></div>
    </div>
  </div>
  <!--遮盖屏幕-->
  <div id="alertBackground" class="alertBackground"></div>
  <div id="dialogBackground" class="dialogBackground"></div>

  <div id='background' class='background'></div>
  <div id='progressBar' class='progressBar'>数据加载 ... ...</div>
  <div style="display:none">

</div>
</body>
</html>